package org.swingplus.core.factory;

import org.swingplus.core.factory.config.BeanDefinition;

import javax.annotation.Nullable;

/**
 * 类元数据
 */
public abstract class AbstractBeanDefinition implements BeanDefinition {

    private Object beanClass;


    public void setBeanClassName(@Nullable String beanClassName) {
        this.beanClass=beanClassName;
    }

    ;

    @Nullable
    public String getBeanClassName() {
        return beanClass.getClass().getName();
    }

    ;

    public void setDependsOn(@Nullable String... dependsOn) {

    }

    ;


    public void setScope(@Nullable String scope) {


    }

    ;

    @Nullable
    public String getScope() {
        return "";
    }

    ;


    /**
     * Set whether this bean is a candidate for getting autowired into some other bean.
     * <p>Note that this flag is designed to only affect type-based autowiring.
     * It does not affect explicit references by name, which will get resolved even
     * if the specified bean is not marked as an autowire candidate. As a consequence,
     * autowiring by name will nevertheless inject a bean if the name matches.
     */
    public void setAutowireCandidate(boolean autowireCandidate) {

    }

    ;

    /**
     * Return whether this bean is a candidate for getting autowired into some other bean.
     */
    public boolean isAutowireCandidate() {
        return false;
    }

    ;


    /**
     * Return the constructor argument values for this bean.
     * <p>The returned instance can be modified during bean factory post-processing.
     * @return the ConstructorArgumentValues object (never {@code null})
     */
//    ConstructorArgumentValues getConstructorArgumentValues();

    /**
     * Return if there are constructor argument values defined for this bean.
     * @since 5.0.2
     */
//    default boolean hasConstructorArgumentValues() {
//        return !getConstructorArgumentValues().isEmpty();
//    }

    /**
     * Return the property values to be applied to a new instance of the bean.
     * <p>The returned instance can be modified during bean factory post-processing.
     * @return the MutablePropertyValues object (never {@code null})
     */
//    MutablePropertyValues getPropertyValues();

    /**
     * Return if there are property values values defined for this bean.
     * @since 5.0.2
     */
    public void setBeanClass(@Nullable Class<?> beanClass) {
        this.beanClass=beanClass;
    }

}
